import wx

class wxclass(wx.Frame):
    def __init__(self,paranet,id):
        wx.Frame.__init__(self,paranet,id, 'First Window', size=(300,200))   
        panel=wx.Panel(self)
        test = wx.TextEntryDialog(None, 'Name?', 'Title','enter name' )
        if test.ShowModal() == wx.ID_OK:
            apples = test.GetValue()
            
        wx.StaticText(panel, -1, apples, (10,10))
        
if __name__ == "__main__":
    app=wx.PySimpleApp()
    frame=wxclass(paranet=None, id=1)
    frame.Show()
    app.MainLoop()